<include file="Index:header" />
<!--头部 end -->
<!--左栏 starts -->
<div class="container-fluid">
		<div class="row-fluid">
			<include file="left" />

			<div id="content" class="span10">
			<!-- content starts -->
<!--左栏 end -->
<ul class="breadcrumb">
      <li>
        <a href="__APP__/TIFAWEB_DSWJCMS.html">首页</a> <span class="divider">/</span>
      </li>
      <li class="active">轮播图片</li>
    <div  class="pull-right"> <a data-toggle="modal" data-rel="tooltip" href="#aDdit">添加轮播图片</a></div>
</ul>
<table class="table table-striped table-bordered table-condensed">
            <thead>
              <tr>
                <th>ID</th>
                <th>标题</th>
                <th>类型</th>
                <th>添加时间</th>
                <th>图片</th>
                <th>状态</th>
                <th>排序</th>
                <th>操作</th>
              </tr>
            </thead>
            <tbody>
                <volist name="list" id="vo">
                <tr>
                <td>
                       {$vo.id}
                </td>
                 <td>
                       {$vo.title}
                </td>
                <td>
                       <if condition="$vo.type eq 0">
                           首页轮播
                       <elseif condition="$vo.type eq 1"/>
                       APP轮播
                       <else/>
                       </if>
                </td>
                <td>
                       {$vo.time|date="Y-m-d H:i:s",###}
                </td>
                <td>
                    <a href="__PUBLIC__/uploadify/uploads/undefined/{$vo.img}" class="cboxElement">
                        <img src="__PUBLIC__/uploadify/uploads/undefined/{$vo.img}" width="180" height="45">
                    </a>
                </td>
                <td class="form-inline">
                    <if condition="$vo.state eq 0">
                   <label class="radio"><input type="radio" name="state{$vo.id}" value="0" class="noty" checked data-noty-options='{"text":"修改成功","layout":"center","type":"success"}' onclick='var state=$(this).val();$.post("__APP__/TIFAWEB_DSWJCMS/Basis/savesh", { id: {$vo.id},state:state} );'/> 显示</label>
                  <label class="radio"><input type="radio" name="state{$vo.id}" value="1" class="noty" data-noty-options='{"text":"修改成功","layout":"center","type":"success"}' onclick='var state=$(this).val();$.post("__APP__/TIFAWEB_DSWJCMS/Basis/savesh", { id: {$vo.id},state:state} );'/> 隐藏</label>
                   <else />
                   <label class="radio"><input type="radio" name="state{$vo.id}" value="0" class="noty"data-noty-options='{"text":"修改成功","layout":"center","type":"success"}' onclick='var state=$(this).val();$.post("__APP__/TIFAWEB_DSWJCMS/Basis/savesh", { id: {$vo.id},state:state} );'/> 显示</label>
                  <label class="radio"><input type="radio" name="state{$vo.id}" value="1" checked class="noty" data-noty-options='{"text":"修改成功","layout":"center","type":"success"}' onclick='var state=$(this).val();$.post("__APP__/TIFAWEB_DSWJCMS/Basis/savesh, { id: {$vo.id},state:state} );'/> 隐藏</label>
                  </if>
                </td>
                <td  width="200">

                  <input data-noty-options='{"text":"修改成功","layout":"center","type":"success"}' name="order" type="text" value="{$vo.order}" class="span3 notys" onblur='var order=$(this).val();$.post("__APP__/TIFAWEB_DSWJCMS/Basis/savesh", { id: {$vo.id},order:order} );'/>
                </td>
                <td>
                    <a href="__APP__/TIFAWEB_DSWJCMS/Basis/editshu/{$vo.id}.html" data-rel="tooltip" class="ajax-link icon icon-color icon-edit" title="编辑"></a>
                    <a href="#" data-rel="tooltip" class="icon icon-color icon-trash"title="删除" onclick="if(confirm('是否要删除？'))window.location.href='__APP__/TIFAWEB_DSWJCMS/Basis/delesh/{$vo.id}'"></a>
                </td>
              </tr>
			  <input name="id[]" type="hidden" value="{$vo.id}" />
</volist>
            </tbody>
          </table>
<div>
<div class="span4">

</div>
</div>
<!--底部 -->
<!--添加轮播图片 开始-->
<div id="aDdit" class="modal hide fade">

    <div class="modal-header">
      <a class="close" data-dismiss="modal" >&times;</a>
      <h3>添加轮播图片</h3>
    </div>
    <form method="post"  action='__APP__/TIFAWEB_DSWJCMS/Basis/addsh'>
    <table class="table">
                    <tbody>
                      <tr>
                        <td>
                               标题：
                        </td>
                        <td>
                          <input name="title" type="text" class="span5" placeholder="请输入标题...">
                        </td>
                      </tr>
                      <tr>
                        <td>
                               类型：
                        </td>
                        <td>
                            <select name="type">
                                    <option value="0">首页轮播</option>
                                    <option value="1">APP轮播</option>
                            </select>
                        </td>
                      </tr>
                      <tr>
                        <td>
                               图片：
                        </td>
                        <td>
                          <input id="img" name="img" type="hidden" />
                          <input data-no-uniform="true" type="file" name="file_upload" id="file_upload" />
                        </td>
                      </tr>
                      <tr>
                        <td>
                               链接地址：
                        </td>
                        <td>
                          <input name="url" type="text" class="span6"  value="javascript:void(0)">
                        </td>
                      </tr>
                      <tr>
                        <td>
                               状态：
                        </td>
                        <td class="form-inline">
                          <label class="radio"><input type="radio" name="state" value="0" checked/> 显示</label>
                          <label class="radio"><input type="radio" name="state" value="1" /> 隐藏</label>
                        </td>
                      </tr>
                       <tr>
                        <td>
                               排序：
                        </td>
                        <td>
                          <input name="order" type="text" class="span2"  value="0">
                        </td>
                      </tr>
                    </tbody>

    </table>
    <div class="modal-footer">
        <a href="#" class="btn" data-dismiss="modal">关闭</a>
        <button type="submit" class="btn btn-primary" >确认添加</button>
    </div>
    </form>
</div>
<!--添加轮播图片 结束-->
<include file="Index:footer" />
<!--底部 end-->
